package com.zzkk.database.data;

public class DynamicDataSourceHolder {
    private static final ThreadLocal<DataSourceType> holder = new ThreadLocal<>();

    public static void putDataSource(DataSourceType dataSourceType) {
        holder.set(dataSourceType);
    }

    public static DataSourceType getDataSouce() {
        return holder.get();
    }

    public static void remove(){
        holder.remove();
    }
}
